3.69 \(\int \sqrt {a+b \sec ^2(e+f x)} \sin (e+f x) \, dx\)

Optimal. Leaf size=66 \[ \frac {\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}-\frac {\cos (e+f x) \sqrt {a+b \sec ^2(e+f x)}}{f} \]

[Out]

arctanh(sec(f*x+e)*b^(1/2)/(a+b*sec(f*x+e)^2)^(1/2))*b^(1/2)/f-cos(f*x+e)*(a+b*sec(f*x+e)^2)^(1/2)/f

________________________________________________________________________________________

Rubi [A]  time = 0.05, antiderivative size = 66, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.174, Rules used = {4134, 277, 217, 206} \[ \frac {\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}-\frac {\cos (e+f x) \sqrt {a+b \sec ^2(e+f x)}}{f} \]

Antiderivative was successfully verified.

[In]

Int[Sqrt[a + b*Sec[e + f*x]^2]*Sin[e + f*x],x]

[Out]

(Sqrt[b]*ArcTanh[(Sqrt[b]*Sec[e + f*x])/Sqrt[a + b*Sec[e + f*x]^2]])/f - (Cos[e + f*x]*Sqrt[a + b*Sec[e + f*x]
^2])/f

Rule 206

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTanh[(Rt[-b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[-b, 2]), x]
 /; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rule 217

Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Subst[Int[1/(1 - b*x^2), x], x, x/Sqrt[a + b*x^2]] /; FreeQ[{a,
b}, x] &&  !GtQ[a, 0]

Rule 277

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[((c*x)^(m + 1)*(a + b*x^n)^p)/(c*(m +
1)), x] - Dist[(b*n*p)/(c^n*(m + 1)), Int[(c*x)^(m + n)*(a + b*x^n)^(p - 1), x], x] /; FreeQ[{a, b, c}, x] &&
IGtQ[n, 0] && GtQ[p, 0] && LtQ[m, -1] &&  !ILtQ[(m + n*p + n + 1)/n, 0] && IntBinomialQ[a, b, c, n, m, p, x]

Rule 4134

Int[((a_) + (b_.)*((c_.)*sec[(e_.) + (f_.)*(x_)])^(n_))^(p_.)*sin[(e_.) + (f_.)*(x_)]^(m_.), x_Symbol] :> With
[{ff = FreeFactors[Cos[e + f*x], x]}, Dist[1/(f*ff^m), Subst[Int[((-1 + ff^2*x^2)^((m - 1)/2)*(a + b*(c*ff*x)^
n)^p)/x^(m + 1), x], x, Sec[e + f*x]/ff], x]] /; FreeQ[{a, b, c, e, f, n, p}, x] && IntegerQ[(m - 1)/2] && (Gt
Q[m, 0] || EqQ[n, 2] || EqQ[n, 4])

Rubi steps

\begin {align*} \int \sqrt {a+b \sec ^2(e+f x)} \sin (e+f x) \, dx &=\frac {\operatorname {Subst}\left (\int \frac {\sqrt {a+b x^2}}{x^2} \, dx,x,\sec (e+f x)\right )}{f}\\ &=-\frac {\cos (e+f x) \sqrt {a+b \sec ^2(e+f x)}}{f}+\frac {b \operatorname {Subst}\left (\int \frac {1}{\sqrt {a+b x^2}} \, dx,x,\sec (e+f x)\right )}{f}\\ &=-\frac {\cos (e+f x) \sqrt {a+b \sec ^2(e+f x)}}{f}+\frac {b \operatorname {Subst}\left (\int \frac {1}{1-b x^2} \, dx,x,\frac {\sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}\\ &=\frac {\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {b} \sec (e+f x)}{\sqrt {a+b \sec ^2(e+f x)}}\right )}{f}-\frac {\cos (e+f x) \sqrt {a+b \sec ^2(e+f x)}}{f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.13, size = 98, normalized size = 1.48 \[ \frac {\sqrt {2} \cos (e+f x) \sqrt {a+b \sec ^2(e+f x)} \left (\sqrt {b} \tanh ^{-1}\left (\frac {\sqrt {a \cos ^2(e+f x)+b}}{\sqrt {b}}\right )-\sqrt {a \cos ^2(e+f x)+b}\right )}{f \sqrt {a \cos (2 (e+f x))+a+2 b}} \]

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[a + b*Sec[e + f*x]^2]*Sin[e + f*x],x]

[Out]

(Sqrt[2]*Cos[e + f*x]*(Sqrt[b]*ArcTanh[Sqrt[b + a*Cos[e + f*x]^2]/Sqrt[b]] - Sqrt[b + a*Cos[e + f*x]^2])*Sqrt[
a + b*Sec[e + f*x]^2])/(f*Sqrt[a + 2*b + a*Cos[2*(e + f*x)]])

________________________________________________________________________________________

fricas [A]  time = 0.84, size = 182, normalized size = 2.76 \[ \left [-\frac {2 \, \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) - \sqrt {b} \log \left (\frac {a \cos \left (f x + e\right )^{2} + 2 \, \sqrt {b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) + 2 \, b}{\cos \left (f x + e\right )^{2}}\right )}{2 \, f}, -\frac {\sqrt {-b} \arctan \left (\frac {\sqrt {-b} \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right )}{b}\right ) + \sqrt {\frac {a \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right )}{f}\right ] \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)*(a+b*sec(f*x+e)^2)^(1/2),x, algorithm="fricas")

[Out]

[-1/2*(2*sqrt((a*cos(f*x + e)^2 + b)/cos(f*x + e)^2)*cos(f*x + e) - sqrt(b)*log((a*cos(f*x + e)^2 + 2*sqrt(b)*
sqrt((a*cos(f*x + e)^2 + b)/cos(f*x + e)^2)*cos(f*x + e) + 2*b)/cos(f*x + e)^2))/f, -(sqrt(-b)*arctan(sqrt(-b)
*sqrt((a*cos(f*x + e)^2 + b)/cos(f*x + e)^2)*cos(f*x + e)/b) + sqrt((a*cos(f*x + e)^2 + b)/cos(f*x + e)^2)*cos
(f*x + e))/f]

________________________________________________________________________________________

giac [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: NotImplementedError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)*(a+b*sec(f*x+e)^2)^(1/2),x, algorithm="giac")

[Out]

Exception raised: NotImplementedError >> Unable to parse Giac output: Unable to check sign: (2*pi/x/2)>(-2*pi/
x/2)-8*(1/2*(a*(-sqrt(a+b)*tan(1/2*(f*x+exp(1)))^2+sqrt(a*tan(1/2*(f*x+exp(1)))^4+b*tan(1/2*(f*x+exp(1)))^4-2*
a*tan(1/2*(f*x+exp(1)))^2+2*b*tan(1/2*(f*x+exp(1)))^2+a+b))+a*sqrt(a+b))/(2*sqrt(a+b)*(-sqrt(a+b)*tan(1/2*(f*x
+exp(1)))^2+sqrt(a*tan(1/2*(f*x+exp(1)))^4+b*tan(1/2*(f*x+exp(1)))^4-2*a*tan(1/2*(f*x+exp(1)))^2+2*b*tan(1/2*(
f*x+exp(1)))^2+a+b))-(-sqrt(a+b)*tan(1/2*(f*x+exp(1)))^2+sqrt(a*tan(1/2*(f*x+exp(1)))^4+b*tan(1/2*(f*x+exp(1))
)^4-2*a*tan(1/2*(f*x+exp(1)))^2+2*b*tan(1/2*(f*x+exp(1)))^2+a+b))^2+3*a-b)+1/4*b*atan(1/2*(-sqrt(a+b)*tan(1/2*
(f*x+exp(1)))^2+sqrt(a+b)+sqrt(a*tan(1/2*(f*x+exp(1)))^4+b*tan(1/2*(f*x+exp(1)))^4-2*a*tan(1/2*(f*x+exp(1)))^2
+2*b*tan(1/2*(f*x+exp(1)))^2+a+b))/sqrt(-b))/sqrt(-b))*sign(cos(f*x+exp(1)))/f

________________________________________________________________________________________

maple [A]  time = 0.53, size = 93, normalized size = 1.41 \[ -\frac {\left (a +b \left (\sec ^{2}\left (f x +e \right )\right )\right )^{\frac {3}{2}}}{f a \sec \left (f x +e \right )}+\frac {b \sec \left (f x +e \right ) \sqrt {a +b \left (\sec ^{2}\left (f x +e \right )\right )}}{f a}+\frac {\sqrt {b}\, \ln \left (\sec \left (f x +e \right ) \sqrt {b}+\sqrt {a +b \left (\sec ^{2}\left (f x +e \right )\right )}\right )}{f} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(f*x+e)*(a+b*sec(f*x+e)^2)^(1/2),x)

[Out]

-1/f/a/sec(f*x+e)*(a+b*sec(f*x+e)^2)^(3/2)+1/f/a*b*sec(f*x+e)*(a+b*sec(f*x+e)^2)^(1/2)+1/f*b^(1/2)*ln(sec(f*x+
e)*b^(1/2)+(a+b*sec(f*x+e)^2)^(1/2))

________________________________________________________________________________________

maxima [A]  time = 0.42, size = 88, normalized size = 1.33 \[ -\frac {2 \, \sqrt {a + \frac {b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) + \sqrt {b} \log \left (\frac {\sqrt {a + \frac {b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) - \sqrt {b}}{\sqrt {a + \frac {b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right ) + \sqrt {b}}\right )}{2 \, f} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)*(a+b*sec(f*x+e)^2)^(1/2),x, algorithm="maxima")

[Out]

-1/2*(2*sqrt(a + b/cos(f*x + e)^2)*cos(f*x + e) + sqrt(b)*log((sqrt(a + b/cos(f*x + e)^2)*cos(f*x + e) - sqrt(
b))/(sqrt(a + b/cos(f*x + e)^2)*cos(f*x + e) + sqrt(b))))/f

________________________________________________________________________________________

mupad [B]  time = 6.77, size = 87, normalized size = 1.32 \[ -\frac {\cos \left (e+f\,x\right )\,\sqrt {a+\frac {b}{{\cos \left (e+f\,x\right )}^2}}}{f}-\frac {\sqrt {b}\,\mathrm {asin}\left (\frac {\sqrt {b}\,1{}\mathrm {i}}{\sqrt {a}\,\cos \left (e+f\,x\right )}\right )\,\sqrt {a+\frac {b}{{\cos \left (e+f\,x\right )}^2}}\,1{}\mathrm {i}}{\sqrt {a}\,f\,\sqrt {\frac {b}{a\,{\cos \left (e+f\,x\right )}^2}+1}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(e + f*x)*(a + b/cos(e + f*x)^2)^(1/2),x)

[Out]

- (cos(e + f*x)*(a + b/cos(e + f*x)^2)^(1/2))/f - (b^(1/2)*asin((b^(1/2)*1i)/(a^(1/2)*cos(e + f*x)))*(a + b/co
s(e + f*x)^2)^(1/2)*1i)/(a^(1/2)*f*(b/(a*cos(e + f*x)^2) + 1)^(1/2))

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \sqrt {a + b \sec ^{2}{\left (e + f x \right )}} \sin {\left (e + f x \right )}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)*(a+b*sec(f*x+e)**2)**(1/2),x)

[Out]

Integral(sqrt(a + b*sec(e + f*x)**2)*sin(e + f*x), x)

________________________________________________________________________________________